package com.vca.common.request;

import com.vca.common.vo.UmsPayRefundVo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

/**
 * @Description: 银联商务 全民付 请求对象
 * @Author: Li
 * @Date: 2022/10/27 13:26
 * */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="UmsPaymentRequest对象", description="银联商务 全民付 请求对象")
public class UmsPaymentRequest implements Serializable {

    private static final long serialVersionUID = -3484114108934750059L;

    @ApiModelProperty(value = "状态：wxpay-微信支付，alipay-支付宝，unionpay-云闪付")
    private String payType;

    @ApiModelProperty(value = "微信用户openID")
    private String subOpenId;

    @ApiModelProperty(value="支付宝用户id")
    private String subUserId;

    @ApiModelProperty(value = "支付总金额")
    private BigDecimal totalAmount;

    @ApiModelProperty(value="订单原始金额 打折前的金额")
    private BigDecimal originalAmount;

    @ApiModelProperty(value="银联商户订单号（支付的时候后台生成，不需要填写）")
    private String merOrderNo;

    @ApiModelProperty(value = "微信支付订单号（退款时使用）")
    private String targetOrderId;

    @ApiModelProperty(value="退款金额")
    private BigDecimal refundAmount;

    @ApiModelProperty(value = "主订单号")
    private List<String> orderNos;

    @ApiModelProperty(value = "退款集合")
    private List<UmsPayRefundVo> refundList;

    @ApiModelProperty(value = "子订单号")
    private List<String> merOrderId;

    @ApiModelProperty(value="子订单号")
    private List<SubOrder> subOrder;

    @Data
    public static class SubOrder implements Serializable {

        private static final long serialVersionUID = 6511435014069014377L;

        @ApiModelProperty("子订单号")
        private String subOrderId;

        @ApiModelProperty("子订单金额")
        private BigDecimal totalAmount;
    }

}
